package cn.gem.rainbow.pojo.entity;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.NoArgsConstructor;

import java.util.Set;
@AllArgsConstructor
@NoArgsConstructor
@Builder
public class SysRole {

    private Set<SysPermission> sysPermissionSet;

    public SysRole(int roleId, String roleName, Set<SysPermission> permissionsSet) {
        this.id=roleId;
        this.roleName = roleName;
        this.sysPermissionSet = permissionsSet;
    }

    public Set<SysPermission> getSysPermissionSet() {
        return sysPermissionSet;
    }

    public void setSysPermissionSet(Set<SysPermission> sysPermissionSet) {
        this.sysPermissionSet = sysPermissionSet;
    }

    private Integer id;

    private String roleName;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getRoleName() {
        return roleName;
    }

    public void setRoleName(String roleName) {
        this.roleName = roleName == null ? null : roleName.trim();
    }
}